import request from '@/utils/request'

function login(params) {
  return request({
    url: '/login',
    method: 'post',
    params
  })
}

function logout() {
  return request({
    url: '/logout',
    method: 'post'
  })
}

function getUserInfo(token) {
  return request({
    url: '/user/info',
    method: 'post',
    params: { token }
  })
}

export {
  login,
  logout,
  getUserInfo
}

